package com.example.yskjproject.view.dialog;

import android.app.Dialog;
import android.content.Context;
import android.os.Bundle;
import android.view.View;

import com.example.yskjproject.R;

/**
 * LoadDia
 * <p>
 * 作者：zx
 * 创建时间：2024/5/26
 */
public class MyProgressDialog extends Dialog {


    public MyProgressDialog(Context context) {
        super(context);
    }

    public MyProgressDialog(Context context, int theme) {
        super(context, theme);
    }

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);

        init(getContext());
    }

    private void init(Context context) {
        setCancelable(false);
        setContentView(R.layout.custom1_load_dialog);//设置加载动画的布局
        findViewById(R.id.dialogBg).setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View v) {
                dismiss();
            }
        });
    }

    @Override
    public void show() {
        super.show();
    }

    @Override
    public void hide() {
        super.hide();
    }

}
